import type { Rule } from 'unocss'

export default [
  [
    /^line-clamp-(\d+)$/,
    match => ({
      display: '-webkit-box',
      '-webkit-box-orient': 'vertical',
      '-webkit-line-clamp': match[1],
      overflow: 'hidden'
    })
  ],
  [/^fz-(\d+)$/, match => ({ 'font-size': `${match[1]}px` })],
  [/^flex-(\d+)$/, match => ({ flex: `${match[1]} ${match[1]} 0%` })],
  ['flex', { display: 'flex' }],
  ['flex-center', { display: 'flex', 'justify-content': 'center', 'align-items': 'center' }],
  ['flex-align-center', { 'align-items': 'center' }],
  ['flex-cul', { 'flex-direction': 'column' }],
  ['justify-between', { 'justify-content': 'space-between' }],
  ['justify-end', { 'justify-content': 'flex-end' }],
  ['flex-nowrap', { 'flex-wrap': 'nowrap' }],
  ['justify-center', { 'justify-content': 'center' }],
  ['wh100', { height: '100%', width: '100%' }],
  ['font-bold', { 'font-weight': 'bold' }]
] as Rule[]
